﻿<Window x:Class="WpfVkontacteClient.PhotoViewerWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
		xmlns:carusel="clr-namespace:Carousel;assembly=Carousel"
        Title="Окно просмотра альбомов" Height="450" Width="700" Loaded="Window_Loaded">
	<Grid Background="Silver">
		<Grid.ColumnDefinitions>
			<ColumnDefinition Width="125"/>
			<ColumnDefinition/>
		</Grid.ColumnDefinitions>
		<StackPanel x:Name="stackCombo">
			<TextBlock Text="Источник:" Margin="2,0,0,0"/>
			<ComboBox x:Name="cmbSource" SelectedIndex="0" SelectionChanged="cmbSource_SelectionChanged">
				<ComboBox.Items>
					<ComboBoxItem Content="Мои альбомы"/>
					<ComboBoxItem Content="Альбомы друзей"/>
				</ComboBox.Items>
			</ComboBox>
			<TextBlock Name="txtFriends" Text="Список друзей:" Margin="2,0,0,0" Visibility="Collapsed"/>
			<ComboBox x:Name="cmbFriends" SelectionChanged="cmbFriends_SelectionChanged" ItemsSource="{Binding Path=Friends,Mode=TwoWay}" 
					Visibility="Collapsed" DataContext="{Binding RelativeSource={RelativeSource Mode=FindAncestor, AncestorType=Window}}">
				<ComboBox.ItemTemplate>
					<DataTemplate>
						<StackPanel>
							<TextBlock Text="{Binding FirstName}"/>
							<TextBlock Text="{Binding LastName}"/>
						</StackPanel>
					</DataTemplate>
				</ComboBox.ItemTemplate>
			</ComboBox>
			<TextBlock Text="Список альбомов:" Margin="2,0,0,0" ></TextBlock>
			<ComboBox x:Name="cmbAlbums" SelectionChanged="cmbAlbums_SelectionChanged" >
			</ComboBox>
		</StackPanel>
		<Path x:Name="customPath" Data="M12,547.5 C42.162511,513.31582 74.461354,485.03865 106.5,453 117.17341,442.32659 129.77214,429.27576 150,436.5 166.37237,442.34727 170.32063,462.41031 184.5,469.5 224.8932,489.6966 226.86622,477 271.5,477 304.40934,477 336.48849,480 369,480 411.59476,480 419.75466,476.8472 454.5,456 506.6265,424.7241 532.15114,394.58143 565.5,339 596.94589,286.59019 619.12867,226.14821&#xd;&#xa;654,172.5 673.22938,142.91634 694.17477,98.595136 726,79.5 742.4182,69.649083 753.24869,63 774,63 799.01663,63 788.81699,55.759153 808.5,84" 
			  Margin="12,62.168,-25.5,18.5" Stretch="Fill" Stroke="Transparent" Grid.Column="1"/>
		<carusel:CarouselControl Grid.Column="1" x:Name="carouselContr"  CustomPathElement="{Binding ElementName=customPath}"
								 ItemsSource="{Binding}">
			<carusel:CarouselControl.DataTemplateToUse>
				<DataTemplate>
					<Border BorderBrush="White" BorderThickness="2" CornerRadius="5" Background="DarkGray">
						<Image Source="{Binding Source}" Height="80" Width="65"/>
					</Border>
				</DataTemplate>
			</carusel:CarouselControl.DataTemplateToUse>
		</carusel:CarouselControl>
	</Grid>
</Window>
